import { defineStore } from 'pinia'
import { ref } from 'vue'

export const useImageStore = defineStore('image', () => {
  const selectedImage = ref('')
  const textDirection = ref('auto')

  const setSelectedImage = (image: string) => {
    selectedImage.value = image
  }

  const setTextDirection = (direction: string) => {
    textDirection.value = direction
  }

  return {
    selectedImage,
    textDirection,
    setSelectedImage,
    setTextDirection
  }
})

export default useImageStore 